﻿
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <link href="../../../Scripts/easyUI145/themes/icon.css" rel="stylesheet" type="text/css" />
    <link href="../../../Scripts/easyUI145/themes/default/easyui.css" rel="stylesheet" type="text/css" />
    <link href="../../../../DataUser/Style/ccbpm.css" rel="stylesheet" type="text/css" />
    <script src="../../../Scripts/easyUI145/jquery.min.js" type="text/javascript"></script>
    <script src="../../../Scripts/easyUI145/jquery.easyui.min.js" type="text/javascript"></script>
    <script src="../../../Scripts/jquery-1.7.2.min.js" type="text/javascript"></script>
    <script src="../../../Scripts/easyUI/jquery.easyui.min.js" type="text/javascript"></script>
    <script src="../../../Scripts/QueryString.js" type="text/javascript"></script>
    <script type="text/javascript" src="../../../Scripts/config.js"></script>
    <script type="text/javascript" src="../../../Comm/Gener.js"></script>
    <script src="DDLBar.js" type="text/javascript"></script>
    <script src="../../CCFlowEnum.js" type="text/javascript"></script>
    <script src="../../../Scripts/EasyUIUtility.js" type="text/javascript"></script>
    <script src="../../../Scripts/vue.js"></script>
    <script type="text/javascript">

        $(function () {
            var pkval = GetQueryString("MyPK");
            var en = new Entity("BP.WF.Template.SFlow.SubFlowHandGuide", pkval);
            $("#TB_SQL").val(en.SubFlowGuideSQL);
        });

    </script>
</head>
<body>
    <div id="App">
        <!--<model-component></model-component>-->
        <div id="bar">
        </div>
        <fieldset>
            <legend>设置数据源</legend>
            <br />
            <input type="text" id="TB_SQL" style="width:90%;" />

            <legend id="help">列表批量启动模式</legend>
            <ul style=" color:Gray">
                <li>启动流程的时候点击后发起，弹出子流程的开始节点页面启动子流程。</li>
                <li>按照SQL设置：SELECT No,Name Port_Emp WHERE FK_Dept='@WebUser.FK_Dept' </li>
            </ul>

        </fieldset>
    </div>
    <script type="text/javascript">
        var Baseinfo = new Vue({
            el: '#App',
            data: {
                adminModel: 1,
                orgModel: 0,
                stas: [],
                webuser: null,
                enumVal: SubFlowStartModel.Simple
            },
            created() {

                InitBar(this.enumVal);

            }
        });

        //保存
        function Save() {
            var pkval = GetQueryString("MyPK");
            var en = new Entity("BP.WF.Template.SFlow.SubFlowHandGuide", pkval);
            en.SubFlowStartModel = Baseinfo.enumVal;

            var val = $("#TB_SQL").val();

            if (val == null || val == "") {
                alert("请填写数据源.");
                return;
            }
            en.SubFlowGuideSQL = val;

            en.Update();

            alert("保存成功.");
        }
    </script>

</body>
</html>
